var nohm = require('nohm').Nohm;
var User = require('./models/User.js');

var redis = require('redis');
var cli = redis.createClient();

nohm.setClient(cli);
nohm.setPrefix('battlemages');
var u = new User;
u.p('name', 'luggi');
u.p('pass');
u.p('email', 'foo@bar.com');
u.save(function(err, test){
  if(err){
    console.dir(err, test);
  }else{
    console.dir(u);
  }
var UserModel = new User;

UserModel.find(function (err, ids) {
    console.dir(ids);
    // ids = array of ids
    cli.end();
  });

 });